package com.tkmybatis.exception;

import lombok.AllArgsConstructor;
import lombok.Getter;

@Getter
@AllArgsConstructor
public enum ErrorType {
	
	//1-10为公共错误
	INVALID_PARAMS("1", "参数不正确"),
	REQUEST_SUBMIT("2","重复提交"),
	ACCESS_TOKEN_NULL("3","access_token为空/错误"),
	SIGN_ERROR("SIGN_ERROR","参数签名错误"),
	AUTH_ERROR("AUTH_ERROR","没有权限访问"),
	
	UPLOAD_FILE_ERR("UPLOAD_FILE_ERR", "文件上传失败"),
	UPLOAD_FILE_TYPE_ERR("UPLOAD_FILE_TYPE_ERR", "文件上传失败,格式不对"),
	DOWNLOAD_FILE_ERR("DOWNLOAD_FILE_ERR", "文件下载失败"),
	WORKFLOW_ERR("5", "调用审批流出错"),
	DATA_EXIT("DATA_EXIT", "数据已存在"),
	

	FEIGN_ERR("6", "Feign接口调用超时"),
	GET_USER_ERR("7", "获取用户信息出错"),
	CHECKOUT_ERROR("8","请输入正确的验证码"),
	CODE_SEND_ERROR("9","验证码发送失败"),

	
	FILE_NOT_FOUND_ERR("FILE_NOT_FOUND_ERR", "文件不存在"),

	EXPERT_NOT_EXIT("10","专家信息不存在"),
	EXPERT_MERGE("11","专家正在提交重要信息，不能修改"),
	EXPERT_IS_FREESE("12","专家已经提交冻结"),
	EXPERT_IS_REMOVE("13","专家已经提交出库"),
	EXPERT_NO_CHANGE("14","专家没有修改记录"),
	EXPERT_SYNC_ERROR("15","专家同步数据失败"),
    EXPERT_IS_EXIT("16","专家信息已存在"),
    EXPERT_IS_INBOUND("17","专家已经入库"),
	EXPERT_FREEZE_NOT_EXIT("18","冻结记录不存在"),
	TECH_QUALIFICATION_NOT_EXIT("19","专家技术资格信息不存在"),
    EXPERT_SPECIALTY_EMPTY("21","专家专业不能为空"),
	EXPERT_STUDY_NOT_EXIT("25","专家培训不存在"),
	EXPERT_HIS_NOT_EXIT("26","专家审批历史不存在"),
	SMAP_ORGAN_INFO_ES_NOT_EXIT("30","组织架构不存在"),
	
	EXPORT_EXCEL_ERROR("20","excel导出失败"),
	
	PROGRAM_NOT_EXIT("31","方案不存在"),
	//40以上为系统管理错误
	APPCODE_IS_EXITS("40","应用CODE已存在"),
	ROLECODE_IS_EXITS("41","角色CODE已存在"),
	PERMISSIONCODE_IS_EXITS("42","权限CODE已存在"),
	PERMISSIONCODE_NOT_EXITS("44","权限CODE不存在"),
	MENUCODE_IS_EXITS("43","菜单CODE已存在"),
	ROLE_IS_EXITS("44","角色已存在"),
	TASK_IS_NOT_EXIT("60","任务不存在"),
	PROCESS_START_ERROR("61","流程启动失败"),
	PROCESS_IS_NOT_EXIT("62","流程不存在"),
	PROCESS_SMAP_ORGAN_NOT_EXIT("63","找不到审批人信息"),
	HTTP_ERROR("80","http调用失败"),
	IMPORT_SIZE_ERROR("81","批量导入数量不能超过1000,请分批上传"),
	DECODE_ERROR("82","解密失败"),
	SYS_DEPT_APPROVER_NOT_EXIT("83","部门审批记录不存在"),
	SYS_DEPT_NOT_EXIT("84","部门不存在"),
	EXPERT_PROGRAM_NOT_EXIT("85","方案信息不存在"),
	EXPERT_EDIT_PLANT("86","方案可供抽取人数不足，请重新编辑补抽方案！"),
	PARSE_RESULT_FAIL("30003","解析返回值失败"),
	HFX_VOICECALLBACK_FAIL("30002","专家语音事件回调失败"), 
	HTTP_REQUERT_FAIL("10004","http请求失败"), 
	AESENCRYPT_FAIL("30001","调用专家语音播报AES加密失败"), 
	SPECIFY_PEOPLE("87","指定人数不可大于 方案需求人数！"),
	SPECIFY_PEOPLE_FAIL("87","推送专家语音失败"),
	;
	/**
	 * 错误码
	 */
	private String code;
	/**
	 * 错误信息
	 */
	private String msg;
	
}
